/*
 * File: J_la_T04_q4.c
 *
 * MATLAB Coder version            : 5.2
 * C/C++ source code generated on  : 23-Apr-2025 08:35:30
 */

/* Include Files */
#include "J_la_T04_q4.h"
#include <math.h>
#include <string.h>

/* Function Definitions */
/*
 * J_LA_T04_Q4
 *     U44 = J_LA_T04_Q4(IN1,IN2)
 *
 * Arguments    : const double in1[5]
 *                const double in2[5]
 *                double u44[16]
 * Return Type  : void
 */
void J_la_T04_q4(const double in1[5], const double in2[5], double u44[16])
{
  double t10;
  double t11;
  double t12;
  double t13;
  double t14;
  double t15;
  double t16;
  double t17;
  double t18;
  double t19;
  double t2;
  double t20;
  double t21;
  double t3;
  double t4;
  double t47;
  double t48;
  double t49;
  double t5;
  double t50;
  double t6;
  double t64;
  double t65;
  double t67;
  double t7;
  double t8;
  double t82;
  double t9;
  /*     This function was generated by the Symbolic Math Toolbox version 8.7.
   */
  /*     09-Apr-2025 18:11:48 */
  t2 = cos(in2[0]);
  t3 = cos(in2[1]);
  t4 = cos(in2[2]);
  t5 = cos(in2[3]);
  t6 = cos(in1[0]);
  t7 = cos(in1[1]);
  t8 = cos(in1[2]);
  t9 = cos(in1[3]);
  t10 = sin(in2[0]);
  t11 = sin(in2[1]);
  t12 = sin(in2[2]);
  t13 = sin(in2[3]);
  t14 = sin(in1[0]);
  t15 = sin(in1[1]);
  t16 = sin(in1[2]);
  t17 = sin(in1[3]);
  t18 = t6 * t7;
  t19 = t6 * t15;
  t20 = t2 * t3;
  t21 = t3 * t10;
  t47 = t21 + t2 * t6 * t11;
  t48 = t19 + t3 * t7 * t14;
  t49 = t20 + -(t6 * t10 * t11);
  t50 = t18 + -(t3 * t14 * t15);
  t6 = t7 * t10;
  t65 = (t2 * t11 * t15 + t6 * t14) + t19 * t21;
  t7 *= t2;
  t67 = (t7 * t11 + t18 * t21) + -(t10 * t14 * t15);
  t7 = (t7 * t14 + t19 * t20) + -(t10 * t11 * t15);
  t64 = t4 * t11 * t14 + t12 * t48;
  t2 = (t6 * t11 + t2 * t14 * t15) + -(t18 * t20);
  t3 = t4 * t8;
  t82 = (-(t8 * t11 * t12 * t14) + t3 * t48) + t16 * t50;
  t6 = t4 * t16;
  t15 = (t11 * t12 * t14 * t16 + t8 * t50) + -(t6 * t48);
  t21 = t12 * t16;
  t18 = (t21 * t49 + t8 * t65) + t6 * t67;
  t10 = t8 * t12;
  t20 = (t10 * t47 + t16 * t7) + t3 * t2;
  t19 = (t21 * t47 + -(t8 * t7)) + t6 * t2;
  t7 = (t10 * t49 + -(t16 * t65)) + t3 * t67;
  t3 = t4 * t47 + -(t12 * t2);
  t21 = t5 * t9;
  t10 = t9 * t13;
  u44[0] = (-t17 * t15 + t10 * t64) - t21 * t82;
  u44[1] = (t17 * t19 - t21 * t20) - t10 * t3;
  t6 = t4 * t49 - t12 * t67;
  u44[2] = (-t17 * t18 + t21 * t7) + t10 * t6;
  u44[3] = 0.0;
  t21 = t5 * t17;
  t10 = t13 * t17;
  u44[4] = (-t9 * t15 - t10 * t64) + t21 * t82;
  u44[5] = (t9 * t19 + t21 * t20) + t10 * t3;
  u44[6] = (-t9 * t18 - t21 * t7) - t10 * t6;
  memset(&u44[7], 0, 9U * sizeof(double));
}

/*
 * File trailer for J_la_T04_q4.c
 *
 * [EOF]
 */
